package cn.getech.data.development.constant;

import lombok.Getter;

/**
 * 最后运行状态枚举类
 * @author Administrator
 *
 */
@Getter
public enum JobLogTypeEnum {

	WORKFLOW(0, "作业流"),
	WORKFLOWDEP(1, "作业流依赖"),
	WORKFLOWNODE(2,"作业流任务");

	int code;
	String name;

	JobLogTypeEnum(int code, String message) {
		this.code = code;
		this.name = message;
	}


	public static JobLogTypeEnum ObjOf(Integer code) {
		if (code == null) {
			code = 1;
		}
		for (JobLogTypeEnum s : JobLogTypeEnum.values()) {
			if (s.getCode() == code) {
				return s;
			}
		}
		return null;
	}
}
